package com.shanjige.chatgpt.chatgptweb.enums;

import lombok.AllArgsConstructor;

/**
 * @author qhong
 * @date 2023/2/7 19:04
 **/
@AllArgsConstructor public enum ErrorEnum {
    /**
     * 业务成功
     */
    SUCCESS("200", "Success"),

    //1打头 用户权限 登录异常
    /**
     * 用户未登录或登录信息过期
     */
    NOT_LOGIN("-10", "xman-baseline-leads-web_ErrorEnum_-1521191903"),
    /**
     * 账户未激活
     */
    NOT_ACT("-11", "xman-baseline-leads-web_ErrorEnum_1959015405"),
    /**
     * 账户失效
     */
    DOWN("-12", "xman-baseline-leads-web_ErrorEnum_-217449127"),
    /**
     * 账户停用!
     */
    STOP("-13", "xman-baseline-leads-web_ErrorEnum_-219495964"),
    /**
     * 暂无权限，请联系管理员
     */
    NO_AUTH("-100", "xman-baseline-leads-web_ErrorEnum_611692150"),

    /**
     * 接口调用频繁，请确认后重新请求
     */
    REPEAT("-101", "xman-baseline-leads-web_ErrorEnum_-2015561624"),
    /**
     * 接口调用错误
     */
    API_INVALID("-102", "xman-baseline-leads-web_ErrorEnum_-387810279"),

    //2打头 业务数据异常
    /**
     * 业务异常
     */
    BUSSINESS("-200", "xman-baseline-leads-web_ErrorEnum_616747389"),
    /**
     * 无效的参数
     */
    INVALID_PARAMETER("-201", "xman-baseline-leads-web_ErrorEnum_-882107638"),
    /**
     * 参数不存在
     */
    PARAMETER_NOT_EXISTS("-202", "xman-baseline-leads-web_ErrorEnum_-879137553"),
    /**
     * 参数重复
     */
    PARAMETER_REPEATED("-203", "xman-baseline-leads-web_ErrorEnum_664913742"),
    /**
     * 操作失败
     */
    BIZ_FAILED("-204", "xman-baseline-leads-web_ErrorEnum_789024387"),

    /**
     * 非法类型
     */
    INVALID_TYPE("-205", "xman-baseline-leads-web_ErrorEnum_1182185959"),

    /**
     * 用户过期
     */
    USER_EFFICARY("-401", "xman-baseline-leads-web_ErrorMsg_1182314167"),

    //8打头，数据库异常
    /**
     * SQL异常
     */
    DB_ERROR("-800", "xman-baseline-leads-web_ErrorEnum_79916452"),
    /**
     * 数据不存在
     */
    DB_NO_DATA("-801", "xman-baseline-leads-web_ErrorEnum_-1009561377"),
    /**
     * 数据已存在
     */
    DB_DATA_EXIST("-802", "xman-baseline-leads-web_ErrorEnum_-1005651068");

    public String getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(String errorCode) {
        this.errorCode = errorCode;
    }

    public String getErrorMessage() {
        return errorMessage;
    }

    public void setErrorMessage(String errorMessage) {
        this.errorMessage = errorMessage;
    }

    private String errorCode;
    private String errorMessage;

}